<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@taglib uri="http://www.goodfox.com/jsp/tags/power" prefix="p"%>
<%@taglib uri="http://www.springframework.org/tags" prefix="spring" %>
<%
request.setAttribute("locale",request.getLocale());
request.setAttribute("sessionId",session.getId());
%>
<script type="text/javascript">
function uploadifyComplete(event,Id,fileObj,response,data){
	var webFormEntity = JSON.parse(response);
	for(var i=0;i<webFormEntity.fileEntitys.length;i++){
		var fileEntity=webFormEntity.fileEntitys[i];
		var photoIdPath=fileEntity.showPath.substring(fileEntity.showPath.lastIndexOf("/")+1,fileEntity.showPath.lastIndexOf("."))+";"+fileEntity.showPath;
		addRightPhoto("${tabIndex}","<c:url value='/"+fileEntity.showPath.substr(1)+"'/>",photoIdPath);
	}
}
function uploadifyAllComplete(event,data){
	
}
</script>
<div id="fileQueue" class="fileQueue"></div>
<input id="testFileInput" type="file" name="image" 
   uploader="<c:url value="/resources/uploadify/scripts/uploadify.swf"/>" 
   cancelImg="<c:url value="/resources/uploadify/cancel.png"/>" 
   script="<c:url value="/rights/rightsPhotoUpload.shtml;jsessionid=${sessionId}"/>" 
   scriptData="" 
   folder="/folder" 
   fileQueue="fileQueue" 
   [onComplete="uploadifyComplete"] 
   [onAllComplete="uploadifyAllComplete"] />

